<?php echo form_tag('reportsCustomer/doSOA',array('id'=>'SOAForm','target'=>'_SOA_report',))?>
<?php echo $SOAForm['_csrf_token']?>
<?php echo $SOAForm['customer_iden']?>
<table class="form">
  <tr>
    <th>Customer <?php echo link_to('change','contact/search',array('id'=>'reports_customer_link_change_customer',))?> :</th>
    <td id="reportsCustomerContactListName"><?php echo $contact->getListName()?></td>
  </tr>
  <tr>
    <th><?php echo $SOAForm['owner_iden']->renderLabel()?></th>
    <td><?php echo $SOAForm['owner_iden']?></td>
  </tr>
  <tr>
    <th><?php echo $SOAForm['date_from']->renderLabel()?></th>
    <td><?php echo $SOAForm['date_from']?></td>
    <th><?php echo $SOAForm['date_to']->renderLabel()?></th>
    <td><?php echo $SOAForm['date_to']?></td>
  </tr>
</table>
<center>
  <input type="submit" value="Report"/> | 
  <input type="reset" value="Reset"/>
</center>
</form>

<script language="javascript">
  $(document).ready(function(){
    $('#reports_customer_link_change_customer').click(function(e){
    
      $.get(this.href,{},
        function(content){
          $("#ajMain").show().html(content);
          $("#ajContactPanel").hide();
          $("#reportsCustomerSearchPanel").hide();
          $("#ajContactForm").remove();
          contactDialogMode=301;
        }
      );
      
      e.preventDefault();
    });    
  });
</script>